package com.project.bean;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.util.List;

/**
 * @Title: DeptBean
 * @Package: com.project.bean
 * @Description:
 * @Author: Liang-Xie
 * @Date: 2022/7/15 - 11:21
 */
@SuppressWarnings("all")
@TableName("t_dept")
public class DeptBean {
    @TableId(value = "pk_deptId",type = IdType.AUTO)
    private Integer id;
    @TableField("d_name")
    private String name;
    @TableField(exist = false)//标识该属性没有对应的列
    private Integer emNum;
    @TableField(exist = false)
    private List<EmployeeBean>employeeBeanList;

    public DeptBean(String name) {
        this.name = name;
    }

    @Override
    public String toString() {
        return "DeptBean{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", emNum=" + emNum +
                ", employeeBeanList=" + employeeBeanList +
                '}'+'\n';
    }

    public DeptBean() {
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getEmNum() {
        return emNum;
    }

    public void setEmNum(Integer emNum) {
        this.emNum = emNum;
    }

    public List<EmployeeBean> getEmployeeBeanList() {
        return employeeBeanList;
    }

    public void setEmployeeBeanList(List<EmployeeBean> employeeBeanList) {
        this.employeeBeanList = employeeBeanList;
    }
}
